const str1 = "0 1 2 1";
const time1 = "3";

const cars = readline()
  // const cars = str1
  .split(/\s/g)
  .map((v) => Number.parseInt(v));
const timer = time1;

const getMaxCarNum = (cars, timer) => {
  if (timer === "0" || cars.length === 0) {
    console.log(0);
    return;
  }
  const carsNums = {
    0: 0,
    1: 0,
    2: 0
  };
  cars.forEach((car) => {
    carsNums[car] = carsNums[car] + 1;
  });

  const carNum = [];
  Object.entries(carsNums).forEach(([car, num]) => {
    carNum.push(num);
  });
  const maxCarNum = Math.max(...carNum);

  console.log(maxCarNum);
};

getMaxCarNum(cars, timer);
